home *** CD-ROM | disk | FTP | other *** search
/ TeX 1995 July / TeX CD-ROM July 1995 (Disc 1)(Walnut Creek)(1995).ISO / graphics / circuit_macros / examples / ex1.m4 < prev    next >
Text File  |  1994-03-13  |  736b  |  29 lines

  1. .PS
  2. linewid = 0.75
  3. del = linewid/4
  4. define(`elen_',linewid)
  5.  
  6. LL: Here
  7. up_;
  8. source(up linewid+2*del); llabel(-,v_s,+)
  9. right_
  10. cswitch; llabel(,t = 0,)
  11. iresistor; llabel(,47\`,'\Omega,); {"$i_R$" at last arrow above}
  12. line right_ linewid/2 then down_ del
  13. par_(`iInductor; llabel(,L,) {"$\;i_L$" at last arrow ljust}',
  14.      `capacitor; rlabel(+,v_C,-); llabel(,,C)',
  15.      linewid)
  16. line to (Here,LL) then to LL
  17.  
  18. right_
  19. move to last[].c + (0.05,0)
  20. arc -> cw from rvec_(vscal_(del,Cos(30),-Sin(30)))\
  21.    to rvec_(vscal_(del,Cos(30),Sin(30))) rad del at Here
  22. "$i_2$" at last arc
  23.  
  24. move to LL + (4*del,3*del)
  25. arc -> cw rad 2*del from rvec_(vscal_(2*del,Cos(30),-Sin(30)))\
  26.    to rvec_(vscal_(2*del,Cos(30),Sin(30))) at Here
  27. "$i_1$" at last arc
  28. .PE
  29.